From: Jasper St. Pierre Date: Sun, 10 Mar 2013 02:12:37 +0000 (-0500) Subject: layout: Disable the overview hotcorner when we have a full-screen window open X-Git-Tag: archive/raspbian/50.5-1+rpi1~1^2~1013^2^2~4511 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=29152d30223fc7665aecefed663267a77ea3da88;p=gnome-shell.git layout: Disable the overview hotcorner when we have a full-screen window open For the same reasons that we disable the tray barrier, we should disable hot corners as well -- when users have a full-screen game open, we shouldn't allow overview activation by the hotcorner. https://bugzilla.gnome.org/show_bug.cgi?id=694997 --- diff --git a/js/ui/layout.js b/js/ui/layout.js index d24d1475c..381676dc4 100644 --- a/js/ui/layout.js +++ b/js/ui/layout.js @@ -326,7 +326,7 @@ const LayoutManager = new Lang.Class({ continue; } - let corner = new HotCorner(this, cornerX, cornerY); + let corner = new HotCorner(this, monitor, cornerX, cornerY); corner.setBarrierSize(size); this.hotCorners.push(corner); } @@ -1107,13 +1107,15 @@ Signals.addSignalMethods(LayoutManager.prototype); const HotCorner = new Lang.Class({ Name: 'HotCorner', - _init : function(layoutManager, x, y) { + _init : function(layoutManager, monitor, x, y) { // We use this flag to mark the case where the user has entered the // hot corner and has not left both the hot corner and a surrounding // guard area (the "environs"). This avoids triggering the hot corner // multiple times due to an accidental jitter. this._entered = false; + this._monitor = monitor; + this._x = x; this._y = y; @@ -1247,6 +1249,9 @@ const HotCorner = new Lang.Class({ }, _toggleOverview: function() { + if (this._monitor.inFullscreen) + return; + if (Main.overview.shouldToggleByCornerOrButton()) { this._rippleAnimation(); Main.overview.toggle();